package Demo4;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 殇
 * Date: 2025-06-10
 * Time: 16:09
 */
public class Test {
    public static void bark(IBarking iBarking){
        iBarking.bark();
    }
    public static void swim(ISwimming iSwimming){
        iSwimming.swim();
    }
    public static void run(IRunning iRunning){
        iRunning.run();
    }

    public static void main(String[] args) {
        Cat cat=new Cat("小白");
        Fish fish=new Fish("小黑");
        run(cat);
        bark(cat);
        swim(fish);
    }
}
